﻿using DotNetExtensions.Core.Jobs;
using Quartz;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;

namespace CoreWebSimple
{
    [Job("0/2 * * * * ?")]
    public class PrintJob : IJob
    {
        public Task Execute(IJobExecutionContext context)
        {
            Console.WriteLine($"[{DateTime.Now}] - Hello world");
            return Task.CompletedTask;
        }
    }

    [Job("0/2 * * * * ?", Disabled = false)]
    public class PrintJob2 : IJob
    {
        public Task Execute(IJobExecutionContext context)
        {
            Console.WriteLine($"[{DateTime.Now}] - Hello world 2");
            return Task.CompletedTask;
        }
    }
    
    [Job("0/3 * * * * ?", Disabled = false)]
    public class PrintJob3 : IJob
    {
        public Task Execute(IJobExecutionContext context)
        {
            Console.WriteLine($"[{DateTime.Now}] - Hello world 3");
            return Task.CompletedTask;
        }
    }
}
